package com.kettle.controllerapis;

import com.kettle.config.aop.ControllerWebLog;
import org.springframework.web.bind.annotation.RequestBody;

import com.kettle.model.quartz.JobPost;
import com.kettle.model.quartz.ReturnResult;
import com.kettle.model.rowpage.PageResult;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import springfox.documentation.annotations.ApiIgnore;

@Api(tags = "定时任务接口模块")
public interface QuartzControllerApi {
	
	@ApiOperation(value = "查询定时任务列表")
	@ControllerWebLog(name = "查询定时任务列表", intoDb = false)
	public PageResult listJob(Integer page, Integer rows);
	
	@ApiOperation(value = "添加定时任务信息")
	@ControllerWebLog(name = "添加定时任务信息", intoDb = false)
	public ReturnResult save(JobPost jobDto);

	@ApiOperation(value = "修改定时任务信息")
	@ControllerWebLog(name = "修改定时任务信息", intoDb = false)
	public ReturnResult edit(JobPost jobDto);
	
	@ApiOperation(value = "修改定时任务信息cron")
	@ControllerWebLog(name = "修改定时任务信息cron", intoDb = false)
	public ReturnResult edittime(JobPost jobDto);
	
	@ApiOperation(value = "暂停定时任务信息")
	@ControllerWebLog(name = "暂停定时任务信息", intoDb = false)
	public ReturnResult stopJob(JobPost jobDto);
	
	@ApiOperation(value = "启动定时任务信息")
	@ControllerWebLog(name = "启动定时任务信息", intoDb = false)
	public ReturnResult resumeJob(JobPost jobDto);

	@ApiOperation(value = "删除定时任务信息")
	@ControllerWebLog(name = "删除定时任务信息", intoDb = false)
	public ReturnResult deleteJob(JobPost jobDto);

	@ApiIgnore //禁用
	@ApiOperation(value = "开启全部任务")
	@ControllerWebLog(name = "开启全部任务", intoDb = false)
	public ReturnResult startSchedule();

	@ApiIgnore //禁用
	@ApiOperation(value = "停止全部任务")
	@ControllerWebLog(name = "停止全部任务", intoDb = false)
	public ReturnResult shutdownSchedule();
	
	

}
